<?php defined( '_VALID_MOS' ) or die( include_once("../../404.php") );
$sql = "SELECT `session`.`Ses_Id`, `category`.`Cat_Id`, `category`.`CatName`, `category`.`alias`, `category`.`Description`,
Date_FORMAT(`category`.`date_add`, '%d/%m/%Y') As `date_add`, DATEDIFF(CurDate(), `category`.`date_add`) as `Expires`
FROM `session` INNER JOIN `category` ON `session`.`Ses_Id` = `category`.`SesID`
WHERE `session`.`alias` = ? AND `category`.`Status` = 1
Order by `category`.`Order` desc";
$cmd = $mysqli->prepare($sql);
$cmd->bind_param("s", $_GET["alias"]);
$cmd->execute() or die($mysqli->error);
$cmd->bind_result($Ses_Id, $Cat_Id, $CatName, $alias, $Description, $date_add, $Expires);
$cmd->store_result();
?>
<div id="box_session">
	<div class="tt_right"><div class="tt_left"><div class="tt"><?php echo $meta->title; ?></div></div></div>
	<div id="sub_box_session">
		<div id="sub_box_session1">
			<div class="ct_right">
				<div class="ct">
					<?php while($cmd->fetch()){					
						echo "<div id=title><a href=\"./com_content/category/$alias/".$_GET["item"].".csp\">$Title</a></div>";
						echo "<div id=date>$date_add</div><br>";
						echo "<div id=description>$Description</div><br>";
					}?>
				</div>
			</div>
			<div class="bt_right"><div class="bt_left"><div class="bt"></div></div></div>										
			</div>
	</div>
	<div class="clear"></div>
</div>